package JavaSE.d4;

public class Test23 {
    public static void main(String[] args) {
        double num=Math.random();//获取0-1之间的随机数
        System.out.println(num);
        int a=4;
        System.out.println( Math.sqrt(a));//获取一个数的开方
        a=-4;
        System.out.println( Math.abs(a));//获取绝对值

        double a1=4.5;
        System.out.println(Math.floor(a1));//地板数，向下取整
        System.out.println(Math.ceil(a1));//天花板数，向上取整
    }
}
